@model IEnumerable<WorkFlowCore.BusinessDemo.Web.Entities.Role>

@{
    ViewData["Title"] = "角色管理";
}

<h2>角色列表</h2>

<p>
    <a asp-action="Create" class="btn btn-primary">新增角色</a>
</p>

<table class="table">
    <thead>
        <tr>
            <th>角色编号</th>
            <th>角色名称</th>
            <th>操作</th>
        </tr>
    </thead>
    <tbody>
        @foreach (var item in Model)
        {
            <tr>
                <td>@Html.DisplayFor(modelItem => item.Code)</td>
                <td>@Html.DisplayFor(modelItem => item.Name)</td>
                <td>
                    <a asp-action="Edit" asp-route-id="@item.Id" class="btn btn-sm btn-warning">编辑</a>
                </td>
            </tr>
        }
    </tbody>
</table>
